pp108 : Instance Specific Properties

Instance Specific Properties

This topic describes the XML structure of a process instance.


When a process is instantiated, a property is instantiated in the Message Map to provide instance specific properties. These properties are collectively known as instance properties. They are used to retrieve information about the process instances at runtime, and can be used in process definitions.

XML Structure of Instance Specific Properties

The XML structure of instance specific properties is as follows:

<instanceProperties debugMode="true">
    <processName>GetProducts_vcmdemo10.bpm</processName>
    <processDescription>GetProduct</processDescription>
    <bpmn>/Business Processes/BPMN//Business Processes/GetProduct_vcmdemo10.bpm/11695079978857</bpmn>
    <identifier>{5D8D56E3-523A-47E1-9118-F24520F58201}</identifier>
    <modelSpace>[Organization | ISV]</modelSpace>
    <monitor>true</monitor>
    <startedBy>cn=jdoe,cn=organizational users,o=system,cn=cordys,o=vanenburg.com</startedBy>
    <currentOwner>cn=jdoe,cn=organizational users,o=system,cn=cordys,o=vanenburg.com</currentOwner>
    <organization>o=system,cn=cordys,o=vanenburg.com</organization>
    <startTime>1267526084395</startTime>
    <processInstantiationType>Process Debugger</processInstantiationType>
    <priority>3</priority>
    <parentType>PROCESS</parentType>
</instanceProperties>

Elements in the XML Structure of Instance Specific Properties


The following table describes the elements in the XML structure of instance specific properties:

Element

Description

processName

The name of the process.

processDescription

A description of the process.

bpmn

Stores information regarding the rendering of the process during runtime. This information is used by the PIM to display the process instance details in a graphical format.

identifier

A unique identifier of the process instance.

modelSpace

The place from which the process instances are executed and displayed in Process Instance Manager.

monitor

The monitoring attribute set for the process.

startedBy

The LDAP DN of the user or role that triggered the process instance.

currentOwner

The LDAP DN of the user or role that last triggered the process instance.
Note: Initially, the DN will be the same as the value in the startedBy element. But if the process instance is triggered again by an intermediate user or role, that user or role will be the owner for further operations in the process. For example, assume that a process instance sends a message to a participant and is waiting for a response. The participant in turn sends back a response that triggers the same process instance. The owner for all future operations with the process instance will be the participant whose response triggered the process instance.

organization

The LDAP DN of the user's organization that triggered the process instance.

startTime

The time when the process instance was instantiated. The format of the startTime is usually in 13 digits, where, the last three digits are milliseconds. Consider that the startTime is 1267526084395 where, 395 is milliseconds and doesn't need to be converted to a valid YYYY-MM-DDTHH:mm:SS.ms or UTC format. To convert the format of the startTime of a process instance in a valid YYYY-MM-DDTHH:mm:SS.ms format, do the following, for example:

  • Click the Message Map tab of the business process model in design time. The message map view of the business process model appears.
  • Under Pre Assignments > Source > Process Specific Messages, create message, followed by an element. The created message and elements appear in the Target column of the message map.
  • From Target Process Specific Messages, drag the newly created element on to the Assignments column of the message map.
  • Select Replace Content with Expressionand use the following expression:
    concat 
    (sprintf( "%D(%yyyy-%MM-%dd)T%T(%HH:%mm:%ss)",
    substring( instanceProperties/startTime/text(), 1, 10),
    substring( instanceProperties/startTime/text(), 1, 10)),
     ".",   
    substring( instanceProperties/startTime/text(), 11, 13) 
    )

    The startTime is converted to YYYY-MM-DDTHH:mm:SS.ms format or a valid UTC format as shown below:

    <TestStartTime xmlns="http://schemas.cordys.com/default">
        <Processstarttime>2010-03-02T16:04:44.395</Processstarttime>
    </TestStartTime>
    

processInstantiationType

The source from where the process is triggered.

priority

The execution priority of the process, where priority ranges from 1 to 5, 1 corresponding to very low and 5 corresponding to very high.

parentType

Displays the parent type of the sub process. If we invoke a sub-process from a main process, then parentType is PROCESS, and if we invoke a sub-process from a case, then parentType is CASE.

callerInstance

Displays the sub-process instance id if parentType is PROCESS, and displays the case instance id if parentType is CASE.